/**
 * 2017年3月20日
 */
package cn.edu.bjtu.alex.rewrite;

import java.util.Iterator;
import java.util.Map.Entry;

import cn.edu.bjtu.alex.rewrite.components.Stat;

/**
 * @author Alex
 *
 */
public class StatDriver implements Iterator<Entry<String,Integer>>{
	Context ctx ;
	private Stat lc = null;
	public StatDriver(Context ctx){
		this.ctx = ctx;
	}
	public void fit(){
		lc = new Stat(ctx);
		lc.fit();
	}

	public long getTotalDoc(){
		return lc.getTotalDoc();
	}
	public boolean hasNext() {
		return lc.hasNext();
	}


	public Entry<String, Integer> next() {
		return lc.next();
	}

}
